<%@page import="cn.kgc.news.service.impl.DetailServiceImpl"%>
<%@page import="cn.kgc.news.service.DetailService"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
</head>
<body>
	<%
		//获取传过来的值
		int id = Integer.parseInt(request.getParameter("id"));
		DetailService service = new DetailServiceImpl();
		//执行 删除操作
		int update = service.deleteDetail(id);
		if(update > 0){
			request.setAttribute("msg", "删除成功");
		}else {
			request.setAttribute("msg", "删除失败");
		}
		request.getRequestDispatcher("newsDetailList.jsp")
		.forward(request, response);
	%>
</body>
</html>